package shayu.product.service;

import cn.hutool.db.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import io.renren.common.utils.PageUtils;
import org.springframework.web.bind.annotation.PathVariable;
import shayu.product.entity.AttrEntity;
import shayu.product.vo.AttrGroupRelationVo;
import shayu.product.vo.AttrRespVo;
import shayu.product.vo.AttrVo;

import java.util.List;
import java.util.Map;

/**
 * 商品属性
 *
 * @author xiaoshayu
 * @email xiaoshayu@qq.copm
 * @date 2023-05-03 22:48:57
 */
public interface AttrService extends IService<AttrEntity> {

    PageUtils queryPage(Map<String, Object> params);

    void saveAttr(AttrVo attrVo);

    PageUtils queryBaseAttrPage(Map<String, Object> params, @PathVariable("catelogId") Long catelogId,@PathVariable("type") String type);

    AttrRespVo getAttrInfo(Long attrId);

    void updateAttr(AttrVo attr);

    List<AttrEntity> getRelationAttr(Long attrgroupId);

    void deleteRelation(AttrGroupRelationVo[] vos);

    PageUtils getNoRelationAttr(Long attrgroupId, Map<String, Object> params);

    List<Long> selectSearchAttrIds(List<Long> collect);

}

